package com.aaa.service.impl;

import com.aaa.dao.S_ExamLoginDao;
import com.aaa.entity.ExamPerson;
import com.aaa.service.S_ExamService;
import com.aaa.util.EmpUtil;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;
import java.util.Map;

@Service
public class S_ExamServiceImpl implements S_ExamService {
    @Autowired
    private S_ExamLoginDao dao;

    @Override
    public boolean login(Map map) {
        List<ExamPerson> list =dao.login(map);
        if (list.size()>0){
            EmpUtil.setExamPerson(list.get(0));
            return true;
        }
        return false;
    }
}
